
package com.jiuqi.ccp.generator.form;

import java.text.ParseException;
import java.text.SimpleDateFormat;

import javax.servlet.http.HttpServletRequest;

import org.apache.struts.action.ActionError;
import org.apache.struts.action.ActionErrors;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionMapping;

/**
 * Form for ccpInfoBusidata.
 *
 * @author <a href="http://boss.bekk.no/boss/middlegen/"/>Middlegen</a>
 *
 * @struts.form name="ccpInfoBusidataForm"
 */
public class CcpInfoBusidataForm extends ActionForm {

   private final static SimpleDateFormat FORMAT = new SimpleDateFormat("dd.MM.yyyy hh:mm:ss");

   private java.lang.String _cfbdGuid = null;
   private java.lang.String _cfbLabel = null;
   private java.lang.String _glCode = null;
   private java.math.BigDecimal _busiData = null;
   private java.lang.String _busiYear = null;
   private java.lang.String _caoGuid = null;
   private java.lang.String _remark1 = null;
   private java.lang.String _remark2 = null;
   private java.lang.String _remark3 = null;
   private java.lang.String _remark4 = null;
   private java.lang.String _remark5 = null;

   /**
    * Standard constructor.
    */
   public CcpInfoBusidataForm() {
   }

   /**
    * Returns the cfbdGuid
    *
    * @return the cfbdGuid
    */
   public java.lang.String getCfbdGuid() {
      return _cfbdGuid;
   }

   /**
    * Sets the cfbdGuid
    *
    * @param cfbdGuid the new cfbdGuid value
    */
   public void setCfbdGuid(java.lang.String cfbdGuid) {
      _cfbdGuid = cfbdGuid;
   }
   /**
    * Returns the cfbLabel
    *
    * @return the cfbLabel
    */
   public java.lang.String getCfbLabel() {
      return _cfbLabel;
   }

   /**
    * Sets the cfbLabel
    *
    * @param cfbLabel the new cfbLabel value
    */
   public void setCfbLabel(java.lang.String cfbLabel) {
      _cfbLabel = cfbLabel;
   }
   /**
    * Returns the glCode
    *
    * @return the glCode
    */
   public java.lang.String getGlCode() {
      return _glCode;
   }

   /**
    * Sets the glCode
    *
    * @param glCode the new glCode value
    */
   public void setGlCode(java.lang.String glCode) {
      _glCode = glCode;
   }
   /**
    * Returns the busiData
    *
    * @return the busiData
    */
   public java.math.BigDecimal getBusiData() {
      return _busiData;
   }

   /**
    * Sets the busiData
    *
    * @param busiData the new busiData value
    */
   public void setBusiData(java.math.BigDecimal busiData) {
      _busiData = busiData;
   }
   /**
    * Returns the busiYear
    *
    * @return the busiYear
    */
   public java.lang.String getBusiYear() {
      return _busiYear;
   }

   /**
    * Sets the busiYear
    *
    * @param busiYear the new busiYear value
    */
   public void setBusiYear(java.lang.String busiYear) {
      _busiYear = busiYear;
   }
   /**
    * Returns the caoGuid
    *
    * @return the caoGuid
    */
   public java.lang.String getCaoGuid() {
      return _caoGuid;
   }

   /**
    * Sets the caoGuid
    *
    * @param caoGuid the new caoGuid value
    */
   public void setCaoGuid(java.lang.String caoGuid) {
      _caoGuid = caoGuid;
   }
   /**
    * Returns the remark1
    *
    * @return the remark1
    */
   public java.lang.String getRemark1() {
      return _remark1;
   }

   /**
    * Sets the remark1
    *
    * @param remark1 the new remark1 value
    */
   public void setRemark1(java.lang.String remark1) {
      _remark1 = remark1;
   }
   /**
    * Returns the remark2
    *
    * @return the remark2
    */
   public java.lang.String getRemark2() {
      return _remark2;
   }

   /**
    * Sets the remark2
    *
    * @param remark2 the new remark2 value
    */
   public void setRemark2(java.lang.String remark2) {
      _remark2 = remark2;
   }
   /**
    * Returns the remark3
    *
    * @return the remark3
    */
   public java.lang.String getRemark3() {
      return _remark3;
   }

   /**
    * Sets the remark3
    *
    * @param remark3 the new remark3 value
    */
   public void setRemark3(java.lang.String remark3) {
      _remark3 = remark3;
   }
   /**
    * Returns the remark4
    *
    * @return the remark4
    */
   public java.lang.String getRemark4() {
      return _remark4;
   }

   /**
    * Sets the remark4
    *
    * @param remark4 the new remark4 value
    */
   public void setRemark4(java.lang.String remark4) {
      _remark4 = remark4;
   }
   /**
    * Returns the remark5
    *
    * @return the remark5
    */
   public java.lang.String getRemark5() {
      return _remark5;
   }

   /**
    * Sets the remark5
    *
    * @param remark5 the new remark5 value
    */
   public void setRemark5(java.lang.String remark5) {
      _remark5 = remark5;
   }


   /**
    * Validate the properties that have been set from this HTTP request,
    * and return an <code>ActionErrors</code> object that encapsulates any
    * validation errors that have been found.  If no errors are found, return
    * <code>null</code> or an <code>ActionErrors</code> object with no
    * recorded error messages.
    *
    * @param mapping The mapping used to select this instance
    * @param request The servlet request we are processing
    */
   public ActionErrors validate(ActionMapping mapping, HttpServletRequest request) {
      ActionErrors errors = new ActionErrors();
      // test for nullity
      if(getCfbdGuid() == null) {
         errors.add("cfbdGuid", new ActionError("error.cfbdGuid.required"));
      }
      // TODO test format/data
      return errors;
   }
}
